Skip to content

Fix #2147: redirect both java and scala std out/err #2148

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Mar 30, 2017

Conversation

felixmulder
Copy link
Contributor

No description provided.

try {
// Do classloading magic and running here:
val ucl = new URLClassLoader(Array(dir.toURI.toURL))
val cls = ucl.loadClass("Test")
val meth = cls.getMethod("main", classOf[Array[String]])

val ps = new PrintStream(printStream)
System.setOut(ps)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is thread-unsafe

How did this work in the CI before? how did other tests pass?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Probably because all run tests execute without being interrupted.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also, CI didn't fail because of tests - it failed because we restarted the agent (aka slave). New commit makes it safe.

@felixmulder felixmulder force-pushed the topic/fix-#2147 branch 2 times, most recently from e23b33e to 0b1cb37 Compare March 29, 2017 16:02
@nicolasstucki
Copy link
Contributor

LGTM

@nicolasstucki nicolasstucki merged commit 97e241c into scala:master Mar 30, 2017
@allanrenucci allanrenucci deleted the topic/fix-#2147 branch December 14, 2017 19:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants